from django.urls import path
from . import views


# Create your views here.

def trigger_error(request):
    division_by_zero = 1 / 0


urlpatterns = [
    path('joblist/', views.joblist),
    path('job/<int:job_id>/', views.detail),
    path('resume/add/', views.ResumeCreateView.as_view(), name='resume-add'),
    path('resume/<int:pk>/', views.ResumeDetailView.as_view(), name='resume-detail'),
    path('create_hr_user/', views.create_hr_user, name='create_hr_user'),
    path('sentry-debug/', trigger_error),
    path('', views.joblist, name='name'),
]

from django.conf import settings

if settings.DEBUG:
    # 有XSS 漏洞的视图页面
    urlpatterns += [path('detail_resume/<int:resume_id>/', views.detail_resume, name='detail_resume'), ]
